package main

import (
	"google.golang.org/grpc"
	wt "gitee.com/go_rpc_echo/wechat"
	"golang.org/x/net/context"
	"log"
)

func main(){
	//var opts []grpc.DialOption
	conn,_ := grpc.Dial("111.231.100.76:10006",grpc.WithInsecure())
	defer conn.Close()
	client:=wt.NewWechatRpcClient(conn)
	ctx := context.Background()
	wi:=&wt.WechatInfo{Appid:"wx740e5c66b6aba432",Secret:"d3a1b00c50c2657c33693a1d88b9eb5a"}
	ret,err := client.Notice(ctx,&wt.NoticeRequest{Title:"hello",Time:"2017-01-01 12:09:08",Content:"sdhsak爱都萨克雷健身卡打开jahsdsahjsdk",Info:wi})
	log.Println(ret)
	log.Println(err)

}
